package com.anolesoft.amljmes.fourteenDispatch.service.impl;

import com.anolesoft.amljmes.fourteenDispatch.controller.TaskViewController;
import com.anolesoft.amljmes.fourteenDispatch.dto.MesPlanDispatchingDto;
import com.anolesoft.amljmes.fourteenDispatch.service.info.TaskViewService;
import com.anolesoft.amljmes.fourteenDispatch.service.mapper.TaskViewServiceMapper;
import com.anolesoft.common.core.domain.LoginUser;
import com.anolesoft.yr.util.SecurityUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class TaskViewServiceImpl implements TaskViewService {
    @Autowired
    TaskViewServiceMapper taskViewServiceMapper;

    @Override
    public List<MesPlanDispatchingDto> querySendWorkersInfo(TaskViewController.DemoVO demoVO) {
        List<MesPlanDispatchingDto> querySendWorkersDto=taskViewServiceMapper.querySendWorkersSQL(demoVO);
        return querySendWorkersDto;
    }

    @Override
    public List<MesPlanDispatchingDto> queryHandlersInfo(TaskViewController.DemoVO demoVO) {
        LoginUser loginUser = SecurityUtils.getLoginUser();
        List<MesPlanDispatchingDto> queryHandlersDto=taskViewServiceMapper.queryHandlersSQL(demoVO);
        return queryHandlersDto;
    }

    @Override
    public List<MesPlanDispatchingDto> queryPgrForJiedan(TaskViewController.DemoVO demoVO) {
        return this.taskViewServiceMapper.queryPgrForJiedan(demoVO);
    }

    @Override
    public List<MesPlanDispatchingDto> queryCzzForJiedan(TaskViewController.DemoVO demoVO) {
        return this.taskViewServiceMapper.queryCzzForJiedan(demoVO);
    }
}
